package com.ys.entity.base;

import java.util.Date;
import javax.persistence.Table;
import com.alibaba.fastjson.annotation.JSONField;
import com.ys.annotation.YsField;
import com.ys.entity.base.BaseEntity;
/**
*/
@Table(name="TB_Material", catalog="Id")
public class TbMaterial extends BaseEntity<TbMaterial> {

	@YsField(nameDataBase="Id", nameJava="id", typeDataBase="bigint")
	private Long id;
	@YsField(nameDataBase="Code", nameJava="code", typeDataBase="varchar")
	private String code;
	@YsField(nameDataBase="Name", nameJava="name", typeDataBase="varchar")
	private String name;
	@YsField(nameDataBase="Remark", nameJava="remark", typeDataBase="varchar")
	private String remark;
	@YsField(nameDataBase="Status", nameJava="status", typeDataBase="tinyint")
	private Integer status;
	@JSONField(format = "yyyy-MM-dd HH:mm:ss")
	@YsField(nameDataBase="CreateTime", nameJava="createTime", typeDataBase="datetime")
	private Date createTime;
	@JSONField(format = "yyyy-MM-dd HH:mm:ss")
	@YsField(nameDataBase="UpdateTime", nameJava="updateTime", typeDataBase="datetime")
	private Date updateTime;

	public Long getId() {
		return id;
	}
	public TbMaterial setId(Long id) {
		this.id = id;
		return this;
	}
	public String getCode() {
		return code;
	}
	public TbMaterial setCode(String code) {
		this.code = code;
		return this;
	}
	public String getName() {
		return name;
	}
	public TbMaterial setName(String name) {
		this.name = name;
		return this;
	}
	public String getRemark() {
		return remark;
	}
	public TbMaterial setRemark(String remark) {
		this.remark = remark;
		return this;
	}
	public Integer getStatus() {
		return status;
	}
	public TbMaterial setStatus(Integer status) {
		this.status = status;
		return this;
	}
	public Date getCreateTime() {
		return createTime;
	}
	public TbMaterial setCreateTime(Date createTime) {
		this.createTime = createTime;
		return this;
	}
	public Date getUpdateTime() {
		return updateTime;
	}
	public TbMaterial setUpdateTime(Date updateTime) {
		this.updateTime = updateTime;
		return this;
	}

	public static TbMaterial tbMaterial(
		String code,
		String name,
		String remark,
		Integer status
			) {
		TbMaterial entity = new TbMaterial();
		entity.setCode(code);
		entity.setName(name);
		entity.setRemark(remark);
		entity.setStatus(status);
		return entity;
	}
}